{php $tpl_dir = $this->default_tpl;}
{template $tpl_dir, 'header'}
<div class="main clear">
  <div class="col-auto">
  	{template $tpl_dir, 'block_contact'}
   	  <h2 class="crumbs">商机<span>/Business Opportunity</span></h2>
    <div class="sub-nav">商机分类：{if $catid}<a href="{compute_company_url('model', array('catid'=>0))}">{/if}全部{if $catid}</a>{/if}{loop $catid_arr $cid $c}
	{if $catid!=$cid}<a href="{compute_company_url('model', array('catid'=>$cid))}">{/if}
	{$categorys[$cid]['catname']}({$c['num']})
	{if $catid!=$cid}</a>{/if} 
	{/loop}</div>
		 {php $urlrule = yp_makeurlrule(); $b_type = array('1'=>'供应', '2'=>'求购', '3'=>'二手', '4'=>'促销',);$sql = " `userid`='".$array[userid]."'";}
		 {php intval($catid) ? $sql .= " AND `catid`=$catid" : ''; if (intval($_GET['tid'])) $sql .= " AND `tid`='".intval($_GET['tid'])."'";}
		{pc:yp action="lists"  where="$sql" modelid="$modelid" num="15" order="inputtime desc" page="$page" urlrule="$urlrule"}
		  <ul class="news-list">
			{loop $data $r}
                <li><h2><a href="{compute_company_url('model', array('tid'=>$r['tid']))}" class="blue fn" target="_blank">[{$b_type[$r['tid']]}]</a> <a href="{compute_company_url('show', array('catid'=>$r['catid'], 'id'=>$r['id'], 'page'=>1))}" title="{$r[title]}" target="_blank">{$r[title]}</a><span>{date("Y-m-d H:i:s",$r[inputtime])}</span>
                </h2>
                {if $r[description]}<p>{str_cut($r[description],200,'....')}</p>{/if}
                </li>
			{/loop}
		 </ul>
		 <div id="pages" class="text-c">{$pages}</div>
		{/pc}
               
	</div>
</div>
{template $tpl_dir, 'footer'}